

#include <algorithm>
#include <iostream>
#include <queue>
#include <vector>

#include "common/utils.hpp"

int maxDepth(NTreeNode* root) {
    if (root == nullptr) return 0;
    
    int result = 0;
    for (int i = 0, len = root->nodes.size(); i < len; i++) {
        result = std::max(result, maxDepth(root->nodes[i]));
    }

    return result + 1;
}

extern NTreeNode* commonNRoot;

int main() {
    int res = maxDepth(commonNRoot);
    std::cout << "res: " << res << "\n";
}